//
//  WCNRecordCommentCell.m
//  WCN
//
//  Created by wsj2015 on 16/4/6.
//  Copyright © 2016年 ShanghaiCize Trade And Business Co., Ltd. All rights reserved.
//

#import "WCNRecordCommentCell.h"
#import "WCImageView +setImage.h"
#import "WCTSetTextTool.h"
#import "NSString+Utilities.h"
@implementation WCNRecordCommentCell

- (void)awakeFromNib {
    // Initialization code
    
    self.headIcon.layer.masksToBounds = YES;
    self.headIcon.layer.cornerRadius = self.headIcon.bounds.size.width/2;
    self.backgroundColor = kAppBg;
    self.selectionStyle = UITableViewCellSelectionStyleNone;
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}
- (void)setModel:(WCNRecordCommentModel *)model
{
    _model = model;
    [self.headIcon wsjSetImageWithUrl:model.avatarFileId withPlaceImageName:@"Patient_default"];
    [WCTSetTextTool setTextView:self.nameLabel text:model.name initText:@""];
    [WCTSetTextTool setTextView:self.commentLabel text:model.comment initText:@""];
    
    [WCTSetTextTool setTextView:self.timeLabel text:[NSString timeToString:[model.commentTime longLongValue]] initText:nil];
    
}
@end
